﻿using Logistics.BLL;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace Logistics.Web
{
    public partial class Edittruck : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                Model.Truck t = BLL.TruckBLL.Eshow(Request.QueryString["id"]);
                txtchedui.Value = t.FK_TeamID.ToString();
                txtstate.Value = t.State.ToString();
            }
        }

        protected void Button1_Click(object sender, EventArgs e)
        {
            if (BLL.TruckBLL.updatetruck(txtchedui.Value,txtstate.Value,Request.QueryString["id"])>0)
            {
                Response.Redirect("~/truckshow.aspx");
            }
        }
    }
}